package studio.xiaoyun.core.parameter.criterion;

import java.util.Arrays;
import java.util.List;

import studio.xiaoyun.core.parameter.Parameter;

public class CriterionIsNull extends Criterion {
	private static final long serialVersionUID = 5635848383964803775L;
	private String propertyName;

	protected CriterionIsNull(String propertyName) {
		this.propertyName = propertyName;
	}

	@Override
	public List<String> getPropertyName() {
		return Arrays.asList(propertyName);
	}

	@Override
	public String getQuery(Parameter parameter) {
		return "%s is null";
	}

}
